home *** CD-ROM | disk | FTP | other *** search
/ Aminet 1 (Walnut Creek) / Aminet - June 1993 [Walnut Creek].iso / aminet / gfx / misc / emath_3d_v1_0.lzh / emath3D.doc next >
Text File  |  1992-08-19  |  11KB  |  260 lines

  1. Emath-3D V1.0  DOCUMENT                               18.08.1992
  2. ***********************                               **********
  3.  
  4.  
  5.  
  6. DISTRIBUTION NOTICE
  7. -------------------
  8.  
  9.    This program can be freely distributed provided that the doc file is also 
  10. distributed with the program. No modification is allowed for the program file 
  11. and the doc file. No profit can be made upon this product other than diskette 
  12. and copying expenses without a written permission from me. 
  13.  
  14.    This program is a SHAREWARE. If you find the program useful and utilize it
  15. I ask you to send $10-$20 to the below address. This will make you a registered
  16. user.  The registration will enable you to get new versions of this product 
  17. directly from me. Also I am going to send you other programs that I develop.
  18. The bug reports are welcomed. If you are going to report a bug please write
  19. your system's configuration explicitly. For your all contacts please do not
  20. forget to write your name and address.
  21.  
  22. My mail address :  ( valid forever )
  23.  
  24.   ULTRA A.S.
  25.   Erhan OZTOP
  26.   P.K. 567
  27.          ANTALYA - TURKEY 
  28.          
  29.          
  30. My email address:   E63256@TRMETU.BITNET  ( valid at least until oct.1993 ) 
  31.  
  32. Bug reporting and other questioning can be done by emailing if you have
  33. network access.
  34.  
  35.  
  36.  
  37.     
  38. INTRODUCTION TO EMATH-3D V1.0 
  39. ----------------------------- 
  40.  
  41. Emath-3D is a mathematical tool, it has been designed to help viewing 
  42. mathematical functions. Using this program, you can plot any ( almost )
  43. function. The program features
  44.     
  45.     * Both polar and rectangular function evaluation is possible.
  46.     * Various rendering styles are supported.
  47.     * It is possible to view the plotted expression from any angle.
  48.     * Satisfactory grid resolution ( 180x180 is possible if your system has
  49.       enough memory )
  50.     * Different screen modes are supported.
  51.     * Runs on a 512 Kb amiga
  52.     * Appreciatable speed enables reasonable working speed on a standard 
  53.       amiga
  54.     * Friendly user interface, all controls are located on a pop up half 
  55.       screen.
  56.     * Works on versions 1.2,  1.3,  2.0 , as far as I know.
  57.     * Works on NTSC ( It should at least )
  58.  
  59. The program can be executed from cli by using below formats. ( assuming 
  60. that the name of the program is Emath )
  61.   1 ) Emath
  62.   2 ) Emath <grid>
  63.   3 ) Emath <x grid> x <y grid> 
  64.   
  65. In case of (1) Emath will allow a maximum of       33 x 33       grid resolution.
  66. In case of (2) Emath will allow a maximum of   <grid> x <grid>   grid resolution.
  67. In case of (3) Emath will allow a maximum of <x grid> x <y grid> grid resolution.
  68.  
  69. the grid values must be in the range [1..180]
  70.  
  71.  
  72. THE CONTROL PANEL
  73. -----------------
  74.  
  75.    * All the controls are located on the pop up half screen. You can toggle the
  76. screen with right mouse button. Using this button the screen will pop up or
  77. disappear. The title line of the control panel is used as an information line.
  78. Information line displays messages, program mode, rendering mode and finally 
  79. the depth of the drawing screen.
  80. There is a total of 4 expression specific string gadgets. The first one is 
  81. for the rectangular mode, the other three which are initially inactive is used
  82. by the polar evaluation routine.
  83. For both polar and rectangular modes, you have two variables named 'x' and 'y'
  84. which are traced over a user defined rectangle.
  85.  
  86. The following functions are implemented:
  87. EXP,LN,LOG,ABS
  88. SIN,COS,TAN, 
  89. ASIN,ACOS,ATAN,
  90. SINH,COSH,TANH,
  91. ASINH,ACOSH,ATANH, 
  92.  
  93. pi (=ATAN(1)*4 ... ) and e (=EXP(1) .. ) are predefined constants.
  94.  
  95. Standard operator precedence is used in expression evaluation.( association is
  96. from left to right ) The expression evaluation is not case sensitive. Once you 
  97. have entered an expression it must be evaluated. The EVALUATION button will 
  98. perform this task. The evaluation is grid dependent, that means altering the 
  99. grid parameters as well as any changes to the expression itself will require
  100. a new evaluation. To see the graphical result of an expression you must use the
  101. SHOW button. It will perform an evaluation if one is necassary. The four arrows 
  102. will perform a rotation of a number of degrees indicated in the ANGLE STEP 
  103. gadget. The COLORS gadged brings up a color selection menu, with builtin spread
  104. and copy functions. The grid resolution can be defined using the GRIDX and GRIDY
  105. gadgets, each defining the number of grid elements in the indicated axis. There
  106. are four gadgets defining the starting and ending boundries, namely XSTART,
  107. YSTART, XEND, YEND. The variable 'x' traces x axis from XSTART to XEND while
  108. the variable 'y' traces y axis from YSTART to YEND.
  109. In the Blend rendering mode, you have opportunity to locate a light source
  110. its which coordinates are defined in SOURCEX, SOURCEY, SOURCEZ gadgets.
  111. The two program modes are toggled by using the MODE gadget. The program
  112. mode can be POLAR or RECTANGULAR.
  113.  
  114. The DRAWMODE gadget selects one of the four drawing modes avaliable.
  115. The drawing modes are:
  116.     * WIREFRAME :No line hiding is performed.
  117.     * NORMAL    :Two user selectable colors is used to differentiate the 
  118.                  bottom and the top of the image drawn.
  119.     * CHEQUERED :A chess board like painting is employed. Bottom/top 
  120.                  differentiation is provided with a different texture for 
  121.                  the bottom.
  122.     * BLEND     :Grid elements are colored according to their distance to a
  123.                  user locatable source. Bottom/top differentiation is as in
  124.                  CHEQUERED mode.
  125.  
  126. There are three gadgets controlling the screen attributes, HIRES, INTERLACE
  127. and DEPTH. After the desired screen attributes are set it is necassary to
  128. press CHANGE SCREEN gadget to open the new screen.
  129.  
  130. The AUTOSHOW gadget enables the autoshow mode where the image is displayed
  131. after a user manipulation that requires a screen redraw.
  132.  
  133. Emath-3D will scale the image so that it can fit to the screen. ( Its aspect
  134. ratio will be preserved.) Emath-3D finds a scale value to scale the image,
  135. this value can be modified by the OVERSCALE gadget. When this feature is on
  136. Emath-3D will multiply the value in the OVER SCALE string gadget with the 
  137. actual scale value to find the final scale value to be used for scaling.
  138. This enables user to resize the image drawn. ( if the overscale value is
  139. greater than 1 the image will get out of the screen boundries, where as a
  140. value less than 1 will cause a smaller image to be drawn)   
  141.  
  142. Emath-3D rescales the image, even if a rotation has been done. This can be
  143. sometimes disturbing. ( The actual projected image will change size as you 
  144. change the angle under which the image is viewed ) To prevent this you can 
  145. use the FIXSCALE gadget. As long as this feature is on the scale value won't
  146. be recalculated, instead the last scale value that was calculated before, will
  147. be used.
  148.  
  149. Xcenter, Ycenter gadgets are used to change the midpoint of the drawing screen.
  150. A value -10 for Ycenter will shift the image 10 pixels above whereas a value
  151. of 20 for Xcenter will shift the image 20 pixels to the right.
  152.  
  153. You can write complex expressions in the gadgets that are used to gather real
  154. values such as Xstart, Ystart, Xend, Yend gadgets. (Although you can't enter
  155. long strings) For example you can write cos(e) in the Xstart gadget. 
  156.  
  157. The TERMINATE gadget  quits the program.
  158.  
  159. LEFT ALT key is used to interrupt the rendering operation.
  160.  
  161.  
  162.  
  163. TECHINICAL NOTES & SYSTEM REQUIREMENTS
  164. --------------------------------------
  165.  
  166.    * The program requires mathtrans.library in the system disk's libs
  167. directory. ( actualy in the logical device LIBS: )
  168.  
  169.    * The program will allow user to evaluate functions with a grid resulotion of
  170. 180x180. But this neends considerable amount of memory. The approximate memory
  171. required for AxB grid resolution can be given as:
  172.  
  173. memory needed  (A+1)*(B+1)*24 bytes.
  174. (naturally you must consider the memory required to load in the program
  175.  itself and the chip memory needed for the drawing screen and the pop up half
  176.  screen.
  177. )
  178. the main continous memory segments needed are given below 
  179. (A+1)*(B+1)*12 + (A+1)*(B+1)*8 + (A+1)*(B+1)*2 + (A+1)*(B+1)*2  = (A+1)*(B+1)*24
  180.  
  181.     * If the program can't open a 320x256x4 screen it will try to open a 
  182. 320x200x4 screen, this will (I hope) enable the program to run on a ntsc system. 
  183. If the second attempt also fails, the program will not quit. You can use the 
  184. program with that state, even if you cannot render anything on the screen.
  185. (You can open a screen that will require less memory than the default screen 
  186.  using CHANGE SCREEN gadget after setting the screen parameters by using  DEPTH,
  187.  HIRES, INTERLACE gadgets. Or you may wish to quit some other tasks running 
  188.  on the background to release some memory to be able to open a drawing screen
  189. )
  190.    * In the rectangular mode the program arranges grid elements ( except for the
  191. WIREFRAME mode ) so that rendering the elements in that order removes the
  192. hidden lines. But for the Polar mode one cannot make such a fast arrangement to 
  193. remove the hidden lines. Instead of employing hidden line algorithms , sorting
  194. is performed. This may take some time if your grid resolution is over 60x60. 
  195. ( acually what is long depends on your system as well as your patience )
  196.  
  197.     * Polar mode evaluation is performed as follows:
  198. For each pair of x,y values the values of the variables R, teta, beta are
  199. calculated. Then these values are used to locate a point in the space. teta
  200. value is used as the meridian value and  beta value is used as the parallel
  201. value on a sphere having radius R. 
  202. Parallel (beta) values range from -pi/2 to pi/2 ( south pole to north pole ).
  203. Meridian (tata) values range from    0  to 2*pi ( from the first meridian to 
  204. the 360th meridian )
  205. So if you keep R fixed (say 1)
  206. trace beta -pi/2 to pi/2
  207. trace teta   0   to 2*pi
  208. You'll get a sphere having radius 1. ( just as the default values in the 
  209. gadgets  R, teta, beta)   
  210.  
  211.     * In case of mathematical error(s) during evaluation, Emath-3D will assign
  212. zero (0) value as the result of the expression that caused the error. The user
  213. is going to be warned about the occurance of the error after the evaluation is
  214. completed.
  215.  
  216.  
  217.    * This program is mainly developed using the MAXON KICK PASCAL V2.0
  218.  
  219.  
  220.  
  221.  
  222.  
  223.  
  224. CONTACT ADDRESS & GREETINGS
  225. ---------------------------
  226.  
  227.   
  228.   My mail address :  ( valid forever )
  229.  
  230.   ULTRA A.S.
  231.   Erhan OZTOP
  232.   P.K. 567
  233.          ANTALYA - TURKEY 
  234.          
  235.          
  236.   My email address:   E63256@TRMETU.BITNET  ( valid at least until oct.1993 )
  237.   
  238.  
  239.  
  240.  
  241.  
  242.  
  243.   * All programming and design by ERHAN OZTOP .
  244.   
  245.   * Special thanks to 
  246.        F.  KAGAN GURKAYNAK for his ideas and general assistance.
  247.        ALP KORAY TASDEMIR  for his comments and network assistance.
  248.      
  249.  
  250.  
  251.   
  252. WARRANTY NOTICE
  253. ---------------
  254.  
  255.    I will be in no way liable for damages, incidental, or consequential,
  256. arising from the use or misuse of the program, EMath-3D or for any other
  257. claim by any other party. No warranty ,explicit or implied, is given upon 
  258. the completeness of the program in the sense that it does what it is supposed
  259. to do. Use the program at your own risk, no responsibilty is undertaken.
  260.